package com.zf.yichat.mapper;

import com.zf.yichat.base.FsMapper;
import com.zf.yichat.dto.StGoodsRedeemedDto;
import com.zf.yichat.dto.StGoodsRedeemedShipmentDto;
import com.zf.yichat.model.StGoodsRedeemed;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface StGoodsRedeemedMapper extends FsMapper<StGoodsRedeemed> {

    /**
     * 查询用户已兑换的商品
     * @param userId
     * @return
     */
    List<StGoodsRedeemedDto> queryRedeemedGoodsList(@Param("userId") Long userId);

    /**
     * 查询用户已兑换的商品列表
     * @param goodsTitle
     * @param userId
     * @param state
     * @param shipmentTime
     * @return
     */
    List<StGoodsRedeemedShipmentDto> queryRedeemedGoodsShipmentList(@Param("goodsTitle") String goodsTitle,
                                                                    @Param("userId") Long userId,
                                                                    @Param("nickName") String nickName,
                                                                    @Param("state") String state,
                                                                    @Param("createTime") String createTime,
                                                                    @Param("shipmentTime") String shipmentTime);
}